/**
 * fileName:  UpholdManager.java
 * author:  Lei
 * Company:  Cloudland Studio
 * Createdate:  2014-2-22 下午3:44:55
 *
 * All rights Reserved, Designed By cloudland Copyright(C) 2010-2020
 *   
 * Modification  History:
 *     Date           Author        Version        
 * -------------------------------------------
 * 2014-2-22          Lei            1.0        
 *
 * Why & What is modified:
 * 1.0: 文件创建
 */
package org.cloudland.commercial.uphold;

import org.cloudland.commercial.uphold.handler.AccountStore;
import org.cloudland.commercial.uphold.handler.AuthorizeStore;
import org.cloudland.commercial.uphold.handler.ResourcesStore;
import org.cloudland.commercial.uphold.handler.User;
import org.cloudland.commercial.uphold.handler.support.AccountStoreImpl;
import org.cloudland.commercial.uphold.store.persisten.AccountPersistence;
import org.cloudland.udap.UdapFactory;
import org.cloudland.udap.database.support.ibatis.pers.ManagerMapper;

 /**
 * <pre> 
 * 后台管理类，用于提供用户接口，资源维护接口，账号维护接口及权限维护接口。
 * </pre>
 * @ClassName  UpholdManager
 * @author  Lei
 * @version  %I%, %G%
 * @see  
 * @since   JDK1.6
 *
 */
public class UpholdManager {
	
	private static UpholdManager uphold = new UpholdManager();
	
	/**
	 * accountStore 账户维护实例对象
	 */
	private AccountStoreImpl accountStore = null;
	
	/**
	 * <pre>
	 * 获取后台管理类实例
	 * </pre>
	 *
	 * @return 后台管理实例 
	 */
	public static UpholdManager getInstance() {
		return uphold;
	}
	
	/**
	 * <pre>
	 * 私有构造函数，静止手动创建。
	 * </pre>
	 *   
	 */
	private UpholdManager() {
		// 初始化账户维护对象
		accountStore = new AccountStoreImpl(new AccountPersistence(UdapFactory.getPersistence(ManagerMapper.class)));
	}
	
	/**
	 * <pre>
	 * 获取用户操作接口
	 * </pre>
	 *
	 * @return 用户操作接口
	 */
	public User getUser() {
		return null;
	}
	
	/**
	 * <pre>
	 * 获取账号信息维护对象。
	 * </pre>
	 *
	 * @return  账号信息维护对象
	 */
	public AccountStore getAccountStore(){
		return accountStore;
	}
	
	/**
	 * <pre>
	 * 获取访问资源维护对象
	 * </pre>
	 *
	 * @return 资源维护对象  
	 */
	public ResourcesStore getResourcesStore() {
		return null;
	}
	
	/**
	 * <pre>
	 * 获取授权维护信息接口
	 * </pre>
	 *
	 * @return 授权维护对象
	 */
	public AuthorizeStore getAuthorizeStore() {
		return null;
	}

}
